package com.yootk.filter;

import jakarta.servlet.FilterChain;
import jakarta.servlet.ServletException;
import jakarta.servlet.annotation.WebFilter;
import jakarta.servlet.http.HttpFilter;
import jakarta.servlet.http.HttpServletRequest;
import jakarta.servlet.http.HttpServletResponse;

import java.io.IOException;

/**
 * 过滤器执行顺序
 */
//@WebFilter("/*")
public class FilterA extends HttpFilter {

    @Override
    protected void doFilter(HttpServletRequest request, HttpServletResponse response, FilterChain chain) throws IOException, ServletException {
        System.out.println("【AFilter.doFilter()】AAAAAAAAAAAAA");
        chain.doFilter(request, response); // 跳转到目标处理路径
    }
}
